//
//  CTHomePageView.h
//  ConstellationTalk_0.1
//
//  Created by riley on 15/6/5.
//  Copyright (c) 2015年 riley chu. All rights reserved.
//

#import <UIKit/UIKit.h>
@class CTHotSpotsItem;
@class CTSubjectItem;
@class CTComment;
@class CTHotSpotsDetailItem;
@class CTListDetailUser,CTTopic;

typedef enum {
    CTHomePageViewTypeNoData = 1,
    CTHomePageViewTypeDefault
}CTHomePageViewType;


@protocol CTHomePageViewDelegate;

@interface CTHomePageView : UIView

@property(nonatomic,assign)id<CTHomePageViewDelegate>delegate;
@property(nonatomic,setter=setClassificationInfoArr:)NSArray * classficationArray;
@property(nonatomic,setter=setSubjectItem:)CTSubjectItem * subjectItem;
@property(nonatomic,setter=setHotSpotsDetailArr:)NSArray * hotSpotsDetailArray;
@property(nonatomic,strong)CTHotSpotsItem * currentSlelectedClassificationItem;


- (instancetype)initWithType:(CTHomePageViewType)type;

-(void)selectCurretGroup:(CTTopic *)item;

-(void)refresh;
-(void)refreshPullDownEnd;
-(void)refreshPullUpEnd;

-(void)reloadData;

@end


@protocol CTHomePageViewDelegate <NSObject>

-(void)classificationAction:(CTHomePageView *)view
                   withItem:(CTHotSpotsItem *)itm;

-(void)refreshPullDown:(CTHomePageView *)view;
-(void)refreshPullUp:(CTHomePageView *)view;


//主题代理
-(void)checkAction:(CTHomePageView *)view;
-(void)shareAction:(CTHomePageView *)view;


//在请求失败后，没数据，重新刷新
-(void)reloadViewAction:(CTHomePageView *)view;

/**
*@brief 点击评论总数
*/
- (void)commentCountAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击评论第一条
 */
- (void)commentHitFirstLabelAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击评论第二条
 */
- (void)commentHitSecondLabelAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击评论第一条头像
 */
- (void)commentHitFirstHeadAction:(CTHomePageView *)view withItem:(CTComment *) item;
/**
 *@brief 点击评论第二条头像
 */
- (void)commentHitSecondHeadAction:(CTHomePageView *)view withItem:(CTComment *)item;
/**
 *@brief 点击头像
 */
- (void)hitHeadAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击大图
 */
- (void)hitPicImageBtnAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item withImageView:(UIImageView *)imageView;
/**
 *@brief 点赞
 */
- (void)hitFavourBtnAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item withBool:(BOOL) favBool;
/**
 *@brief 点击评论按钮
 */
- (void)hitCommentBtnaction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击分享按钮
 */
- (void)hitShareBtnAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item withImage:(UIImage *) shareImg;
/**
 *@brief 点击更多按钮
 */
- (void)hitMoreBtnAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item;
/**
 *@brief 点击点赞的人的头像
 */
- (void)hitFavBtnHeadAction:(CTHomePageView *)view withItem:(CTListDetailUser *)item;
/**
 *@brief 点击关注按钮
 */
- (void)hitAttentionBtnAction:(CTHomePageView *)view withItem:(CTHotSpotsDetailItem *)item withBool:(BOOL)attenBool;
/**
 *@brief 点击话题
 */
- (void)hitTopicBtnAction:(CTHomePageView *)view withItem:(CTTopic *)item;



@end